import Router from "koa-router";
import * as todoController from "../controllers/todo.controller";

const router = new Router({
  prefix: "/api/todo",
});

// 任务查询列表
router.get("/list", todoController.list);

// 新建任务
router.post("/create", todoController.create);

// 删除任务
router.post("/remove", todoController.remove);

// 搜索任务
router.get("/search", todoController.search);



export default router;